home *** CD-ROM | disk | FTP | other *** search
/ VRML 2.0 Sourcebook (2nd Edition) / VRML 2.0 Sourcebook CD [md5 fed90f4f9c39d5a60d477058775c7e21].iso / book / mac / ch25 / torch2.wrl < prev    next >
Text File  |  1996-09-23  |  1KB  |  69 lines

  1. #VRML V2.0 utf8
  2. # The VRML 2.0 Sourcebook
  3. # Copyright [1997] By
  4. # Andrea L. Ames, David R. Nadeau, and John L. Moreland
  5. Transform {
  6.     translation 0.0 0.0 0.2
  7.     scale 0.5 0.5 0.5
  8.     children [
  9.     # Torch handle
  10.         Transform {
  11.             translation 0.0 -0.75 0.0
  12.             rotation 1.0 0.0 0.0 3.14
  13.             children Shape {
  14.                 appearance DEF Gray Appearance {
  15.                     material Material {
  16.                         diffuseColor  0.4 0.4 0.4
  17.                         specularColor 0.7 0.7 0.7
  18.                     }
  19.                 }
  20.                 geometry Cone {
  21.                     height 1.5
  22.                     bottomRadius 0.15
  23.                 }
  24.             }
  25.         },
  26.     # Fire pot
  27.         DEF Ring Shape {
  28.             appearance USE Gray
  29.             geometry Cylinder {
  30.                 height 0.1
  31.                 radius 0.4
  32.                 top    FALSE
  33.                 bottom FALSE
  34.             }
  35.         },
  36.         Transform { translation 0.0 0.2 0.0 children USE Ring },
  37.     # Fire pot detail (eliminated)
  38.     # Mounting bracket (eliminated)
  39.     # Flames
  40.         DEF Flames Shape {
  41.             # No appearance, use emissive shading
  42.             geometry IndexedFaceSet {
  43.                 coord Coordinate {
  44.                     point [
  45.                          0.25 0.0 0.00,  0.15 1.0 0.10,
  46.                          0.05 0.0 0.15,  0.18 0.0 0.05,
  47.                          0.00 1.2 0.05, -0.10 0.0 0.05,
  48.                         -0.00 0.0 0.15, -0.13 0.8 0.10,
  49.                         -0.25 0.0 0.00,
  50.                     ]
  51.                 }
  52.                 color Color {
  53.                     color [
  54.                         1.0 0.0 0.0,  0.9 0.5 0.0,
  55.                         1.0 0.0 0.0,  0.9 0.3 0.0,
  56.                         1.0 1.0 0.0,  0.9 0.3 0.0,
  57.                         0.7 0.1 0.2,  0.9 0.8 0.0,
  58.                         1.0 0.0 0.0,
  59.                     ]
  60.                 }
  61.                 coordIndex [
  62.                     0, 1, 2, -1,  3, 4, 5, -1,  6, 7, 8, -1,
  63.                 ]
  64.             }
  65.         }
  66.     # Additional Flames (eliminated)
  67.     ]
  68. }
  69.